package com.example.chapter02;

import androidx.appcompat.app.AppCompatActivity;

import android.content.Intent;
import android.os.Bundle;
import android.widget.TextView;

public class ShowActivity extends AppCompatActivity {
TextView textView;
    @Override
    protected void onCreate(Bundle savedInstanceState) {
        super.onCreate(savedInstanceState);
        System.out.println("到达show");
        setContentView(R.layout.activity_show);
        textView=findViewById(R.id.textView2);
        Intent intent=getIntent();
        Bundle bundle=intent.getBundleExtra("bundle");




        //读取数据
        User user=new User();
        user.getUser(this);
        String username= bundle.getString("username");




       textView.setText(user.toString());
    }

}
